package com.chao.common.util.reaction;

import com.chao.common.util.reaction.Reaction;

import java.util.List;

/**
 * 数据库列表查询和分页查询  统一返回对象
 * @param <T>
 */
public class PageList<T> implements Reaction {

    /**
     * 分页数据总数
     */
    private Integer total;

    /**
     * 数据列表
     */
    private List<T> list;

    public PageList(){}

    public PageList(Integer total, List<T> list) {
        this.total = total;
        this.list = list;
    }

    public Integer getTotal() {
        return total;
    }

    public void setTotal(Integer total) {
        this.total = total;
    }

    public List<T> getList() {
        return list;
    }

    public void setList(List<T> list) {
        this.list = list;
    }
}
